abstract class Vue {
  name: string

  protected constructor(name?: string) {
    this.name = name
  }

  getName(): string {
    return this.name
  }

  abstract setName(name: string): void
}

class React extends Vue {
  constructor() {
    super()
  }

  setName(name: string) {
    this.name = name
  }
}

const app = new React()
app.setName('小曼丝袜')
console.log(app.getName());